<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true"
    CodeFile="Customers.aspx.cs" Inherits="Customers" %>

<%@ Register Assembly="System.Web.DynamicData, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"
    Namespace="System.Web.DynamicData" TagPrefix="cc1" %>
<%--<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Customer</title>
</head>--%>
<%--<body>
    <form id="form1" runat="server">
    <div>--%>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <title>Customers</title>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <table border="0" cellpadding="1" width="100%">
        <tr>
            <td width="15%">
                Customer ID:
            </td>
            <td>
                <asp:TextBox ID="txtCustID" runat="server" Width="148px"></asp:TextBox>
            </td>
        </tr>
        <tr>
            <td>
                Company Name:
            </td>
            <td>
                <asp:TextBox ID="txtCompanyName" runat="server" Width="148px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="errorCompanyName" runat="server" ControlToValidate="txtCompanyName"
                    ErrorMessage="Please Enter Company Name"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td>
                Contact Name:
            </td>
            <td>
                <asp:TextBox ID="txtContactName" runat="server" Width="148px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="errorContactName" runat="server" ControlToValidate="txtContactName"
                    ErrorMessage="Please Enter Contact Name"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td>
                Contact Tile:
            </td>
            <td>
                <asp:TextBox ID="txtContactTitle" runat="server" Width="148px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="errorContactTitle" runat="server" ControlToValidate="txtContactTitle"
                    ErrorMessage="Please Enter Contac Title"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td>
                Address:
            </td>
            <td>
                <asp:TextBox ID="txtAddress" runat="server" Width="148px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="errorAddress" runat="server" ControlToValidate="txtAddress"
                    ErrorMessage="Please Enter Address"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td>
                City:
            </td>
            <td>
                <asp:TextBox ID="txtCity" runat="server" Width="148px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="errorCity" runat="server" ControlToValidate="txtCity"
                    ErrorMessage="Please Enter City"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td>
                Region:
            </td>
            <td>
                <asp:TextBox ID="txtRegion" runat="server" Width="148px"></asp:TextBox>
            </td>
        </tr>
        <tr>
            <td>
                Postal Code:
            </td>
            <td>
                <asp:TextBox ID="txtPostalCode" runat="server" Width="148px"></asp:TextBox>
                <asp:RangeValidator ID="errorPostalCode" runat="server" ControlToValidate="txtPostalCode"
                    ErrorMessage="Wrong Postal Code" MaximumValue="99999" MinimumValue="10000" Type="Integer"></asp:RangeValidator>
            </td>
        </tr>
        <tr>
            <td>
                Country:
            </td>
            <td>
                <asp:DropDownList ID="cbCountry" runat="server" Height="22px" Width="155px">
                    <asp:ListItem></asp:ListItem>
                    <asp:ListItem>Brazil</asp:ListItem>
                    <asp:ListItem>Finland</asp:ListItem>
                    <asp:ListItem>USA</asp:ListItem>
                    <asp:ListItem>Italy</asp:ListItem>
                    <asp:ListItem>Germany</asp:ListItem>
                    <asp:ListItem>Mexico</asp:ListItem>
                    <asp:ListItem>Argentina</asp:ListItem>
                    <asp:ListItem>Switzerland</asp:ListItem>
                    <asp:ListItem>Sweden</asp:ListItem>
                    <asp:ListItem>Austria</asp:ListItem>
                    <asp:ListItem>UK</asp:ListItem>
                    <asp:ListItem>Poland</asp:ListItem>
                    <asp:ListItem>Canada</asp:ListItem>
                    <asp:ListItem>Ireland</asp:ListItem>
                    <asp:ListItem>France</asp:ListItem>
                    <asp:ListItem>Norway</asp:ListItem>
                    <asp:ListItem>Venezuela</asp:ListItem>
                    <asp:ListItem>Belgium</asp:ListItem>
                    <asp:ListItem>Spain</asp:ListItem>
                    <asp:ListItem>Denmark</asp:ListItem>
                    <asp:ListItem>Portugal</asp:ListItem>
                </asp:DropDownList>
                <asp:RequiredFieldValidator ID="errorCountry" runat="server" ControlToValidate="cbCountry"
                    ErrorMessage="Please Choose Country"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td>
                Phone:
            </td>
            <td>
                <asp:TextBox ID="txtPhone" runat="server" Width="148px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="errorPhone" runat="server" ControlToValidate="txtPhone"
                    ErrorMessage="Please Enter Phone Number" Display="Dynamic"></asp:RequiredFieldValidator>
                <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="txtPhone"
                    ErrorMessage="Wrong Phone Number" ValidationExpression="\(?\d?\d?\d?\)?\ *\d\d\d\-?\ ?\d\d\d\d\d*"
                    Display="Dynamic"></asp:RegularExpressionValidator>
            </td>
        </tr>
        <tr>
            <td>
                Fax:
            </td>
            <td>
                <asp:TextBox ID="txtFax" runat="server" Width="149px"></asp:TextBox>
                <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ControlToValidate="txtFax"
                    ErrorMessage="Wrong Fax" ValidationExpression="\(?\d?\d?\d?\)?\ *\d\d\d\-?\ ?\d\d\d\d\d*"
                    Display="Dynamic"></asp:RegularExpressionValidator>
            </td>
        </tr>
    </table>
    <table>
        <div>
            <tr>
                <td colspan="4">
                    <asp:Button ID="btnNew" runat="server" Text="New" Width="65px" OnClick="btnNew_Click"
                        CausesValidation="False" />
                    <asp:Button ID="btnAdd" runat="server" Text="Add" Width="65px" OnClick="btnAdd_Click" />
                    <asp:Button ID="btnUpdate" runat="server" Text="Update" Width="65px" OnClick="btnUpdate_Click" />
                    <asp:Button ID="btnDelete" runat="server" Text="Delete" Width="65px" OnClick="btnDelete_Click"
                        CausesValidation="False" />
                </td>
            </tr>
        </div>
        <tr>
            <td colspan="3">
                <asp:TextBox ID="txtSearchName" runat="server" Width="210px"></asp:TextBox>
                <asp:DropDownList ID="cbSearch" runat="server" Width="179px">
                    <asp:ListItem>Company Name</asp:ListItem>
                    <asp:ListItem>Country</asp:ListItem>
                    <asp:ListItem>City</asp:ListItem>
                </asp:DropDownList>
                <asp:Button ID="btnSearch" runat="server" Text="Search" OnClick="btnSearch_Click"
                    CausesValidation="False" />
            </td>
        </tr>
        <tr>
            <td colspan="1">
                <asp:Button ID="btnReload" runat="server" Text="Reload" OnClick="btnReload_Click"
                    CausesValidation="False" />
            </td>
        </tr>
    </table>
    <asp:GridView ID="gvCustomer" runat="server" Width="300px" OnPageIndexChanging="gvCustomer_PageIndexChanging"
        OnSelectedIndexChanged="gvCustomer_SelectedIndexChanged" AutoGenerateColumns="false">
        <Columns>
            <asp:BoundField DataField="custid" HeaderText="Customer ID" />
            <asp:BoundField DataField="companyname" HeaderText="Company Name" />
            <asp:BoundField DataField="contactname" HeaderText="Contact Name" />
            <asp:BoundField DataField="contacttitle" HeaderText="Contact Title" />
            <asp:BoundField DataField="address" HeaderText="Address" />
            <asp:BoundField DataField="city" HeaderText="City" />
            <asp:BoundField DataField="region" HeaderText="Region" />
            <asp:BoundField DataField="postalcode" HeaderText="Postal Code" />
            <asp:BoundField DataField="country" HeaderText="Country" />
            <asp:BoundField DataField="phone" HeaderText="Phone" />
            <asp:BoundField DataField="fax" HeaderText="Fax" />
        </Columns>
    </asp:GridView>
    <%-- </div>
    </form>
</body>
</html>--%>
</asp:Content>
